﻿<%@ Register TagPrefix="FTB" Namespace="FreeTextBoxControls" Assembly="FreeTextBox" %>

<%@ Page Language="c#" ValidateRequest="false" MasterPageFile="" Codebehind="ItemEdit.aspx.cs" AutoEventWireup="true" Inherits="THANHTUNGO.Portal.Modules.NEWS.Pages.ItemEdit" %>

<asp:Content ID="Content1" runat="server" ContentPlaceHolderID="MainContent">
    <div class="ModuleContent">
    <table id="Table2" border="0" cellpadding="0" cellspacing="0" width="100%" height="100%">
        <tr valign="top">
            <td valign="top">
                <table class="Panel" cellspacing="1" cellpadding="6" width="100%">
                    <tr>
                        <td class="LeftColumn" nowrap width="1%" valign="middle" align="right">
                            Danh mục</td>
                        <td class="RightColumn" nowrap="noWrap">
                            <asp:DropDownList ID="cbCategory" runat="server" DataTextField="Name" DataValueField="ID" Width="390px">
                            </asp:DropDownList></td>
                    </tr>
                    <tr>
                        <td class="LeftColumn" valign="middle" nowrap width="1%" align="right">
                            Luồng&nbsp;</td>
                        <td class="RightColumn" nowrap="noWrap">
                            <asp:DropDownList ID="cbFlow" runat="server" DataTextField="Name" DataValueField="ID" Width="390px">
                            </asp:DropDownList></td>
                    </tr>
                    <tr valign="top">
                        <td class="LeftColumn" nowrap width="1%" valign="middle" align="right">
                            Tiêu đề&nbsp;</td>
                        <td class="RightColumn">
                            <asp:TextBox ID="txtTitle" runat="server" CssClass="TextBox" Width="390" Columns="30"></asp:TextBox>
                            <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" CssClass="Error"
                                Display="Dynamic" ErrorMessage="Chưa nhập tiêu đề" ControlToValidate="txtTitle">*</asp:RequiredFieldValidator></td>
                    </tr>
                    <tr>
                        <td class="LeftColumn" valign="top" nowrap width="1%" align="right">
                            Phụ đề&nbsp;</td>
                        <td class="RightColumn">
                            <asp:TextBox ID="txtSubTitle" runat="server" Columns="30" Width="390" Rows="5" TextMode="MultiLine" SkinID="MultiLineTextBox"></asp:TextBox>
                            <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="txtSubTitle"
                                CssClass="Error" Display="Dynamic" ErrorMessage="Chưa nhập phụ đề">*</asp:RequiredFieldValidator></td>
                    </tr>
                    <tr valign="top">
                        <td class="LeftColumn" nowrap="nowrap" valign="middle" width="1%" align="right">
                            Hình minh họa</td>
                        <td class="RightColumn">
                            <asp:FileUpload ID="FileUpload1" runat="server" Width="390px" /></td>
                    </tr>
                    <tr valign="top">
                        <td align="right" class="LeftColumn" nowrap="nowrap" valign="middle" width="1%">
                        </td>
                        <td class="RightColumn">
                            hoặc URL:
                            <asp:TextBox ID="txtUrl" runat="server" Columns="30" CssClass="TextBox" Width="338px"></asp:TextBox></td>
                    </tr>
                    <tr>
                        <td class="LeftColumn" nowrap="nowrap" valign="middle" width="1%" align="right">
                            Từ khóa</td>
                        <td class="RightColumn">
                            <asp:TextBox ID="txtKeywords" runat="server" Columns="30" CssClass="TextBox" Width="390"></asp:TextBox>
                            <asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" ControlToValidate="txtAuthors"
                                CssClass="Error" Display="Dynamic" ErrorMessage="Chưa nhập từ khóa">*</asp:RequiredFieldValidator></td>
                    </tr>
                    <tr>
                        <td class="LeftColumn" nowrap="nowrap" valign="middle" width="1%" align="right">
                            Tác giả</td>
                        <td class="RightColumn">
                            <asp:TextBox ID="txtAuthors" runat="server" Columns="30" CssClass="TextBox" Width="390"></asp:TextBox>
                            <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ControlToValidate="txtTitle"
                                CssClass="Error" Display="Dynamic" ErrorMessage="Chưa nhập tác giả">*</asp:RequiredFieldValidator></td>
                    </tr>
                    <tr valign="top">
                        <td class="LeftColumn" nowrap valign="top" width="1%" align="right">
                            Nội dung&nbsp;</td>
                        <td class="RightColumn">
                        <FTB:FreeTextBox id="txtContent"
			                toolbarlayout="ParagraphMenu,FontFacesMenu,FontSizesMenu,FontForeColorsMenu,FontForeColorPicker,FontBackColorsMenu,FontBackColorPicker|Bold,Italic,Underline,Strikethrough,Superscript,Subscript,RemoveFormat|JustifyLeft,JustifyRight,JustifyCenter,JustifyFull;BulletedList,NumberedList,Indent,Outdent;CreateLink,Unlink,InsertImage|Cut,Copy,Paste,Delete;Undo,Redo,Print,Save|SymbolsMenu,StylesMenu,InsertHtmlMenu|InsertRule,InsertDate,InsertTime|InsertTable,EditTable;InsertTableRowAfter,InsertTableRowBefore,DeleteTableRow;InsertTableColumnAfter,InsertTableColumnBefore,DeleteTableColumn|InsertForm,InsertTextBox,InsertTextArea,InsertRadioButton,InsertCheckBox,InsertDropDownList,InsertButton|InsertDiv,EditStyle,InsertImageFromGallery,Preview,SelectAll,WordClean,NetSpell"
			                runat="Server"
			                DesignModeCss="FreeTextBox.css" ImageGalleryPath="~/images/Modules/NEWS/" ImageGalleryUrl="ftb.imagegallery.aspx?rif={0}&cif={0}" Width="100%"		 
			                />
                        </td>
                    </tr>
                    <tr valign="top">
                        <td align="right" class="LeftColumn" nowrap="nowrap" valign="middle" width="1%">
                            Đánh giá</td>
                        <td class="RightColumn">
                            <asp:DropDownList ID="cbRates" runat="server" Width="390px">
                                <asp:ListItem>1</asp:ListItem>
                                <asp:ListItem>2</asp:ListItem>
                                <asp:ListItem>3</asp:ListItem>
                                <asp:ListItem>4</asp:ListItem>
                                <asp:ListItem Selected="True">5</asp:ListItem>
                                <asp:ListItem>6</asp:ListItem>
                                <asp:ListItem>7</asp:ListItem>
                                <asp:ListItem>8</asp:ListItem>
                                <asp:ListItem>9</asp:ListItem>
                                <asp:ListItem>10</asp:ListItem>
                            </asp:DropDownList></td>
                    </tr>
                    <tr valign="top">
                        <td align="right" class="LeftColumn" nowrap="nowrap" valign="middle" width="1%">
                            Lượt xem</td>
                        <td class="RightColumn">
                            <asp:TextBox ID="txtTotalView" runat="server">0</asp:TextBox></td>
                    </tr>
                    <tr valign="top">
                        <td class="LeftColumn" nowrap="nowrap" valign="middle" width="1%" align="right">
                            Trạng thái</td>
                        <td class="RightColumn">
                            <asp:DropDownList ID="cbStatus" runat="server" Width="390px">
                                <asp:ListItem Value="Writting">Đang viết</asp:ListItem>
                                <asp:ListItem Selected="True" Value="Waiting">Chờ duyệt</asp:ListItem>
                            </asp:DropDownList></td>
                    </tr>
                </table><asp:Panel ID="Panel2" runat="server" Width="100%" CssClass="PanelFooter">
                    <table id="Table3" cellspacing="1" cellpadding="6" width="100%" border="0">
                        <tr>
                            <td align="right" nowrap="nowrap">
                            </td>
                            <td align="right" nowrap="noWrap" width="1%">
                            Người cập nhật:
                                <asp:Label ID="lblCreatedBy" runat="server"></asp:Label></td>
                            <td align="right" nowrap="nowrap" width="1">
                                |</td>
                            <td nowrap="nowrap" width="1%">
                            Ngày cập nhật:
                                <asp:Label ID="lblCreationTime" runat="server"></asp:Label></td>
                        </tr>
                    </table>
                </asp:Panel>
                <br />
                <div style="text-align:center">
                                <asp:LinkButton ID="btnUpdate" runat="server" Text="Ghi" OnClick="btnUpdate_Click" Width="80px"></asp:LinkButton>
                                <asp:LinkButton ID="btnCancel" runat="server" Text="Quay lại" CausesValidation="False" OnClick="btnCancel_Click" Width="80px"></asp:LinkButton>
                                <asp:LinkButton ID="btnDelete" runat="server" Text="Xóa" CausesValidation="False" OnClick="btnDelete_Click" OnClientClick="return confirm('Bạn có muốn xóa bài viết này không?')" Width="80px"></asp:LinkButton></div><br>
                <div align="center">
                    <asp:ValidationSummary ID="ValidationSummary1" runat="server" HeaderText="Có các lỗi sau:"
                        ShowMessageBox="True" ShowSummary="False" />
                    <br />
                </div>
            </td>
        </tr>
    </table>
    </div>
</asp:Content>
